Repository navigation
feat(loop-init): add cheaperinference model provider - #653
Open
aiapienthusiast wants to merge 1 commit into
Open
aiapienthusiast wants to merge 1 commit into
aiapienthusiast wants to merge 1 commit into
Conversation
Contributor
|
This PR changes paths that must run the real Fork PRs from first-time contributors start with those workflows waiting for approval. A maintainer needs to open the Checks tab and click Approve and run workflows. Until that happens, branch protection will show the PR as blocked even after a review. Content-only PRs ( — loop-engineering fork-pr-gate |
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This PR adds Cheaper Inference as a model provider in
loop-init.It uses the same pattern as #569 (OrcaRouter).
Cheaper Inference is an OpenAI-compatible LLM gateway.
One API key gives access to models from several labs.
Usage:
The default model is
gpt-5.4-mini.Set
CHEAPER_INFERENCE_API_KEYto a key from https://cheaperinference.com/signup.Related issue
None.
Changes
templates/pattern-template.md+ updatedregistry.yaml)tools/Checklist (from CONTRIBUTING)
STATE.md*examples use.examplesuffixdocs/safety.mdtools/<pkg>:cd tools/<pkg> && npm ci && npm testnpm ci && npm run validate:registryTesting / Dogfood
npx @cobusgreyling/loop audit .(or package-local tests) on affected pathsDetails
Files:
tools/loop-init/src/cli.ts: add thecheaperinferenceprovider and themodel/cheaperinferenceprimitive.tools/loop-init/dist/cli.js: rebuilt withnpm run build.tools/loop-init/README.md: document the flag, models and endpoints.tools/loop-init/test/cli.test.mjs: 4 new tests, same as the OrcaRouter tests.The primitive writes these endpoints:
https://api.cheaperinference.com/v1https://api.cheaperinference.com(clients add/v1/messages)Model options:
gpt-5.4-mini,gpt-5.4,claude-sonnet-5,gemini-3.1-pro,deepseek-v4-flash,glm-5.3.Tests:
cd tools/loop-init && npm ci && npm test: 68 of 69 pass. All 4 new tests pass.loop-init prints Loop Ready score after scaffold. It also fails onmainin my environment.npm run check:loop-init: OK.Live check:
gpt-5.4-minireturned a reply through both endpoints in the generated.foundry/stack.yaml.All model ids in the primitive are in the live
GET /v1/modelslist.